<?php

class Application_Form_Password extends Asd_Form
{

    public function init()
    {
        $this->setName('password_form');
        parent::init();
        
        $this->setMethod("POST");
        
        $password = new Zend_Form_Element_Password('password');
        $password->setLabel('Азыркы сыр сөз:')
                 ->setRequired(true)
                 ->addPrefixPath('Asd_Validator', 'Asd/Validator', 'validate')
                 ->addValidator('Passwordmatch')
                 ->addValidator('NotEmpty');
        $this->addElement($password);
        
        $newPassword = new Zend_Form_Element_Password('user_password');
        $newPassword->setLabel('Жаңы сыр сөз:')
                 ->setRequired(true)
                 ->addValidator('NotEmpty');
        $this->addElement($newPassword);
        
        $passwordConfirm = new Zend_Form_Element_Password('password_confirm');
        $passwordConfirm->setLabel('Дагы бир жолу:')
                ->setRequired(true)
                ->addValidator('NotEmpty')
                ->addPrefixPath('Asd_Validator', 'Asd/Validator', 'validate')
                ->addValidator('Passwordconfirm');
        $this->addElement($passwordConfirm);
        
        $submit = new Zend_Form_Element_Submit('submit');
        $submit->setLabel('Өзгөртүү')
                ->setAttrib('class', 'button_big');
        $this->addElement($submit);
    }


}

